<!DOCTYPE html>
<html>
<head th:include="fragment::headerOftable">
</head>
<body>

	<div id="table">
		<div>
			<div class="grid-btn">
				<a class="btn btn-primary" onclick="Menu.newAdd()"><i class="fa fa-plus"></i>&nbsp;新增</a> 
				<a class="btn btn-primary" onclick="Menu.update()"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</a> 
				<a class="btn btn-primary" onclick="Menu.delete()"><i	class="fa fa-trash-o"></i>&nbsp;删除</a>
			</div>
			<table id="menuTable" data-mobile-responsive="true" data-click-to-select="true">
				<thead>
					<tr>
						<th data-field="selectItem" data-checkbox="true"></th>
					</tr>
				</thead>
			</table>
		</div>
	</div>


	<div id="detail" class="panel panel-default" style="display:none;">
		<div class="panel-heading">新增</div>
		<form class="form-horizontal">
			
			<div class="form-group">
				<div class="col-sm-2 control-label">菜单名称</div>
				<div class="col-sm-10">
					<input type="text" name="name" placeholder="菜单名称" class="form-control" />
				</div>
			</div>
			<div class="form-group">
				<div class="col-sm-2 control-label">上级菜单</div>
				<div class="col-sm-10">
					<input type="text" name="parent-name" readonly="readonly" placeholder="上级菜单" class="form-control" style="cursor: pointer;" />
				</div>
			</div>
			<div class="form-group">
				<div class="col-sm-2 control-label">菜单URL</div>
				<div class="col-sm-10">
					<input type="text" name="url" placeholder="菜单URL" class="form-control" />
				</div>
			</div>
			<div class="form-group">
				<div class="col-sm-2 control-label">授权标识</div>
				<div class="col-sm-10">
					<input type="text" name="permission" placeholder="多个用逗号分隔，如：user:list,user:create" class="form-control" />
				</div>
			</div>
			<div class="form-group">
				<div class="col-sm-2 control-label">排序号</div>
				<div class="col-sm-10">
					<input type="number" name="order" placeholder="排序号" class="form-control" />
				</div>
			</div>
			<div class="form-group">
				<div class="col-sm-2 control-label">图标</div>
				<div class="col-sm-10">
					<input type="text"  name="icon"  placeholder="菜单图标" class="form-control" />
					<code style="margin-top: 4px; display: block;">获取图标：http://fontawesome.io/icons/</code>
				</div>
			</div>
			
			<div class="form-group">
				<div class="col-sm-2 control-label">打开位置</div>
				<label class="radio-inline"><input type="radio" name="target" value="main_frame" /> 布局框内 </label> 
				<label class="radio-inline"><input type="radio" name="target" value="_blank" /> 新窗口 </label> 
			</div>
			
			
			<div class="form-group">
				<div class="col-sm-2 control-label"></div>
				<input type="button" id="submit" value="确定" class="btn btn-primary" /> &nbsp;&nbsp;
				<input type="button" value="返回" class="btn btn-warning" onclick="Menu.reload()"/>
			</div>
			
		</form>
	</div>

	<script th:src="@{/statics/js/modules/sys/menu.js}"></script>
</body>
</html>